<script setup>
import { reactive } from 'vue'; 
import {addListsApi} from '../util/request'

const data = reactive({
    addType: {
        name: '',
        price:'',
    }
})

const add = () => {
    addListsApi(data.addType).then(res => {
        
    })
}
</script>

<template>
    <van-cell-group inset>        
        <van-field v-model="data.addType.name" label="水果名" type="text"/>        
        <van-field v-model="data.addType.price" label="价格" type="text"/>
    </van-cell-group>
    <van-button type="primary" @click="add">添加提交</van-button>
</template>

<style>

</style>
